Is my Joda Time format pattern incorrect to produce a `T` and `Z` inside the parsed DateTime output?
Posted
by
Tree
on Stack Overflow
See other posts from Stack Overflow
or by Tree
Published on 2011-01-12T23:31:09Z
Indexed on
2011/01/12
23:53 UTC
Read the original article
Hit count: 214
Using Joda Time's pattern syntax below, this input string:
Sunday, January 09, 2011 6:15:00 PM
becomes this datetime:
2011-01-09T06:15:00.000Z
Code:
String start = "Sunday, January 09, 2011 6:15:00 PM";
DateTimeFormatter parser1 =
DateTimeFormat.forPattern("EEEE, MMMM dd, yyyy H:mm:ss aa");
DateTime startTime = parser1.parseDateTime(start);
Is this format pattern incorrect? If not, what are the T
and Z
doing inside the DateTime output?
2011-01-09T06:15:00.000Z
© Stack Overflow or respective owner